#./modules/mqclient/Makefile
SOURCES = $(wildcard *.cpp)
OBJS = $(patsubst %.cpp,%.o,$(notdir $(SOURCES)))
OBJSD = $(addprefix $(TMP_DIR)mqclient/,$(OBJS))

INCLUDE = -I $(PWD)/thirdparty/libuv/include \
          -I $(PWD)/thirdparty/cjson \
		  -I $(PWD)/thirdparty/librabbitmq \
		  -I $(PWD)/common/util \
		  -I $(PWD)/common/utilc \
		  -I $(PWD)/uvmodules/uvlogplus

all:chkdir mqclient$(TAGTYPE)

chkdir:
	$(shell mkdir -p $(TMP_DIR)mqclient/)

mqclient_static:$(OBJS)
	$(AR) $(OUT_DIR)mqclient.a $(OBJSD)

mqclient_shared:$(OBJS)
	$(GG) -shared -fPIC $(OBJSD) -o $(OUT_DIR)mqclient.so

$(OBJS):%.o:%.cpp
	$(GG) $(INCLUDE) $(GFLAGS) -c $< -o $(TMP_DIR)mqclient/$@

clean:
	rm -rf $(TMP_DIR)mqclient/*.o